Build, test, and submit your app using Xcode, Apple's integrated development environment.

Posts under Xcode tag

200 Posts

Post

Replies

Boosts

Views

Activity

Resolving a "Simulator runtime is not available" error
Some Macs recently received a macOS system update which disabled the simulator runtimes used by Xcode 15, including the simulators for iOS, tvOS, watchOS, and visionOS. If your Mac received this update, you will receive the following error message and will be unable to use the simulator: The com.apple.CoreSimulator.SimRuntime.iOS-17-2 simulator runtime is not available. Domain: com.apple.CoreSimulator.SimError Code: 401 Failure Reason: runtime profile not found using "System" match policy Recovery Suggestion: Download the com.apple.CoreSimulator.SimRuntime.iOS-17-2 simulator runtime from the Xcode To resume using the simulator, please reboot your Mac. After rebooting, check Xcode Preferences → Platforms to ensure that the simulator runtime you would like to use is still installed. If it is missing, use the Get button to download it again. The Xcode 15.3 Release Notes are also updated with this information.
0
0
11k
May ’24
Xcode 27 beta: "Missing package product" for a Swift Package in a registry
I have a project that builds fine in macOS 26 with Xcode 26. On macOS 27 b4 and Xcode beta, the same project can't build because of a framework that should be pulled from a Swift Package from a package-registry (named Registry, for example below), hosted on JFrog. I have the registry set up and have the token in keychain. The resolution of the packages works. But when I build, I get error like this: error: Missing package product 'Registry.Package_Package.Package' (in target 'Target' from project 'Project') . The real package should just be 'Registry.Package'. Any help with that? Is it a bug?
11
2
1.3k
10h
Attributes inspector in Xcode 26
It has been two years since I wrote my a SwiftUI app, and I wanted to start again in Xcode 26. I can no longer see the attributes inspector when I select an element in the canvas. This was an Xcode feature that was very helpful as I am still a novice. Has this feature been deprecated in Xcode 26? And if not, please help explain how I can find and use it.
4
6
1.3k
2d
XCode 27b6 XCUITest clone simulators not visible in Device Hub (No Show Parallel Testing Devices)
Tried to execute our XCUITest test suite with XCode 27b6. The test plan is set to run in parallel. When executing tests locally with XCode 26, I can see the clone simulators executing the test (which is useful for debugging the test). With XCode 27b6 and Device Hub, I do not see the clone simulators executing, nor do I see a setting or menu item in Device Hub to show those clone simulators. There is no equivalent to the "Show Parallel Testing Devices" menu item in the XCode 26 sim. Am I missing something or is this a regression in XCode 27?
1
3
164
3d
Xcode's Background Assets Run scheme option
I just saw the following in the Xcode 27 release notes: Xcode can now serve asset packs to your app while debugging on devices by setting a Background Asset Packs folder in the Run scheme action’s Options tab. (165230494) And sure enough, the option is there. But what do I need to point this to? I tried everything: the path to the built .aar asset pack the path to the .json manifest file the path to the download-manifest.json (for self-hosted asset packs) the path to the directory that actually contains the assets (as also referenced by the manifest file) the path to the directory that contains the manifest file and the asset directory. Nothing works. I always get the same errors on the console: Checking for updates failed: DecodingError.dataCorrupted: Data was corrupted. Debug description: The given data was not valid JSON.. Underlying error: Error Domain=NSCocoaErrorDomain Code=3840 "Unexpected end of file" UserInfo={NSDebugDescription=Unexpected end of file} The asset pack with the ID “MyID” couldn’t be looked up: DecodingError.dataCorrupted: Data was corrupted. Debug description: The given data was not valid JSON.. Underlying error: Error Domain=NSCocoaErrorDomain Code=3840 "Unexpected end of file" UserInfo={NSDebugDescription=Unexpected end of file} The manifest couldn’t be refreshed: DecodingError.dataCorrupted: Data was corrupted. Debug description: The given data was not valid JSON.. Underlying error: Error Domain=NSCocoaErrorDomain Code=3840 "Unexpected end of file" UserInfo={NSDebugDescription=Unexpected end of file} I'm testing on a physical iPhone. Any advice would be appreciated!
0
0
70
3d
can not create iOS 27 Simulator
Apple M1 Pro, 26.5.1 (25F80) XCode 27.0 Beta (27A5194q) Command Line tools for Xcode 27 are installed. Device Hub Version 27.0 (235.4.2) Within device hub I can not create iOS 27 simulators. Only the 26.5 simulators are listed there. I installed the iOS 27.0 SDK. Also deleted and reinstalled it. The computer was restarted. No change. I am unable to create the proper iOS 27 Simulators. Any idea why this is not working? Thanks for the help upfront.
14
1
1.6k
3d
Xcode 27: Bugs / Feedbacks
Hi, I have listed below the Feedbacks for Xcode 27, please have a look at it, considerable time was spent on filing these feedbacks, thanks! Environments All of them were tested on the environment: macOS 26.5.1 (25F80) Xcode 27.0 beta (27A5194q) Feedbacks FB23133706 (Git stage tab) FB23132869 (markdown - code block) FB23132403 (markdown - search) FB23078039 (stash - slow / unresponsive) FB23077930 (stash - allow multiselection) FB23055381 (Run destination - Clear recents) FB23041713 (SwiftUI preview - SwiftData) FB23033844 (Bundle ID) FB23033231 (Device Hub - sizes)
13
1
1.6k
3d
iOS 27 & watchOS 27 Simulator runtimes download but never register (signatureState never becomes "verified")
Environment Xcode 27.0 (Build 27A5194q) macOS 27.0 (Build 26A5353q), Apple Silicon Command Line Tools 27.0 Summary The iOS 27.0 (24A5355p) and watchOS 27.0 (24R5289n) Simulator runtimes download and mount successfully, but never register as usable. Both fail in exactly the same way. Every older runtime (e.g. iOS 26.2 / 23C54) works fine. What I see xcrun simctl list runtimes does NOT list iOS 27 or watchOS 27. They appear only under xcrun simctl runtime list (disk images), as: iOS 27.0 (24A5355p) State: Ready Image Kind: Patchable Cryptex Disk Image Signature State: Unknown Mount Path: /private/var/run/com.apple.security.cryptexd/mnt/... They never get promoted to /Library/Developer/CoreSimulator/Volumes/ the way working runtimes do. Where it actually breaks simdiskimaged finds and mounts the runtime with no error: "Found runtime bundle on disk image at: .../iOS 27.0.simruntime" "Got supported architectures back ... arm64" The runtime IS present in /Library/Developer/CoreSimulator/Images/images.plist, and its cryptex personalization manifest exists in /Library/Developer/CoreSimulator/Cryptex/Personalization/. BUT iOS 27 (24A5355p) and watchOS 27 (24R5289n) are the ONLY two images in the index whose signatureState is not verified. Every other runtime shows signatureState => verified. CoreSimulatorService therefore never registers them. So the cryptex mounts and the personalization ticket is present, but signature verification against that manifest never completes for these two new runtimes. Things I have already tried (no change) Deleted and re-downloaded the runtime via xcodebuild -downloadPlatform iOS (fresh image, identical result) Restarted CoreSimulatorService; ran sudo xcodebuild -runFirstLaunch Full reboot (cryptex re-mounts at boot but is still never verified/promoted) Deleted images.plist and let it rebuild Verified: system clock correct; gs.apple.com and ppq.apple.com reachable on 443; ~85 GB free disk; iphoneos27.0 SDK build (24A5355p) matches the downloaded runtime; simctl runtime match list shows 24A5355p as the chosen/default runtime. The standalone Simulator runtime .dmg for iOS 27 is not yet on Developer Downloads, so xcrun simctl runtime add isn't an option. Questions Is anyone else seeing iOS 27 / watchOS 27 runtimes stuck at Signature State: Unknown / signatureState != verified on this beta? Is there a way to force re-verification of an already-downloaded cryptex runtime without a standalone .dmg? Is this a known issue in the current beta? (FB filed.) Thanks!
2
1
422
4d
Internal PDF links stop working on iOS 27 / macOS 27 beta — every link opens the first page
On iOS 27 beta / Xcode 27.0, PDFDocument.write(to:) no longer serializes destinations for link annotations that are created at runtime. The annotation and its PDFActionGoTo action are both written, but the destination's page reference is not, so every internal link is dead. This worked correctly on iOS 26. PDFs generated on iOS 26 still navigate correctly; the same code on iOS 27 beta produces PDFs whose links are all dead.
1
3
391
4d
Build behaving differently in testflight compared to simulator
Hi all I have an app I’m pretty much done with, and on the Xcode simulator it works perfectly and the IAP shows us when the purchase buttons are clicked but for some reason when it goes to testflight none of the buttons respond, is there any reason that would cause it to behave differently in testflight when its coded correctly and works in the simulator. thanks
0
0
126
1w
Xcode MCP: Is Swift Package dependency management supported?
Hi Apple, I’m exploring the built-in MCP support in Xcode 27 and noticed that the available Xcode MCP tools don’t seem to provide a way for an agent to manage Swift Package dependencies. For example, an agent can inspect and modify source code, build the project, run tests, and diagnose build issues. However, I haven’t found an MCP tool that allows the agent to perform operations such as: Add a Swift Package dependency to an Xcode project Remove a Swift Package dependency Add/remove a package product from a target Change the version/branch/revision requirement of a package dependency For example, I’d like to be able to give an agent an instruction such as: Add https://github.com/xxx/SomePackage.git to the project, use version 1.2.0 or later, and link the SomePackage product to the MyApp target. At the moment, it appears that the agent can identify that the package is missing when compilation fails, but it cannot actually perform the package configuration step through the Xcode MCP tools. Is Swift Package dependency management intentionally not exposed through Xcode MCP at this time? If it is not currently supported, are there plans to expose APIs/tools for managing: Package dependencies Package products Target-package relationships Package version requirements This would be particularly useful for coding agents, since adding a dependency is a common part of an otherwise automated development workflow. I've submitted a request to feedback, the id is FB24676163. Thanks!
0
0
83
1w
AppStore Upcoming Requirement - Scene Delegate Migration Enforcement
My apps are legacy codebases still using AppDelegate instead of SceneDelegate. According to TN3187: Migrating to the UIKit scene-based life cycle, apps should migrate to the scene-based lifecycle. I have the following questions: Is there a specific timeline or deadline for when this migration will be enforced? Will there be deprecation warnings before the assert is triggered? I've tested my app with Xcode 27 beta, and it's not showing any errors or warnings related to this requirement. Based on this, I'm assuming this scene delegate migration may not be relevant for Apple's yearly requirement to submit new apps with the latest iOS SDK, and won't be enforced in April when "apps uploaded to App Store Connect must be built with Xcode 27 or later using an SDK for iOS 27." Can someone confirm if this understanding is correct?
2
0
304
1w
Is it a known issue that Xcode static analyzer hallucinates past results?
[Q] Is it a known issue that the Xcode static analyzer hallucinates past results? Basically, the issue I've been observing for a few releases of Xcode now (including 27b) is that if you run a static analysis, fixes the reported issues and re-run a static analysis, you will get exactly the same results as with the first run. It's as if Xcode did not take into account the fixes. If you clean the builds (cmd + shift + K), and run the analysis again, this time, you will get up-to-date results.
1
0
388
1w
Running tests in Xcode creates random folder Library/Containers/MyApp/Data with .profraw file
I was looking for my app's Application Support folder and was confused to see hundreds of folders with names like 36FE5C78-6D16-4556-8F13-80B0F2E7AD4B-84238-0000088F9B63C05B cluttering the Data folder. Some of these folders are empty, some contain a file named something like 791DC593-238F-4180-9D5D-6ABB7D22A4D3-18720.profraw. It seems that whenever I run any of my tests in Xcode, a new folder is generated and all the old ones are never removed. What's the purpose of these folders and why are they not removed automatically?
0
0
184
1w
Xcode 14 try to build all SPM when building swiftUI preview
HI, I have an issue displaying SwiftUI previews with Xcode 14. My project has iOS and an watchOS Target. It also includes a lot of SPM, most of them only used by the PhoneApp. The project build successfully for both iOS and watchOS. I can see that when building the watch target, only SPM that are included in this target are build for for watchOS The issue is when I try to build a swiftUI preview of the watch target. In this case I can see on the build for Preview log that Xcode try to build ALL spm defined in the Xcode project, including the one that are not used by the watch Target, As a lot if spm are for iOS only, and doesn't build for watchOS, the build for preview fails, and I'm unable to preview my swiftUI views on the AppeWatch. Note that my project is working fine on Xcode 13. This issue is easy to reproduce in any Xcode projects containing a iOS and watchOS target by adding a SPM that is only for iOS. Any workaround to fix this issue ?
18
7
7.4k
1w
Main Camera Access" Capability Missing from Provisioning Profile in Xcode, but is Enabled in Developer Portal
When attempting to build an Apple Vision Pro application written in Swift in Xcode, we get the following status errors: "Provisioning profile [Profile Name] doesn't include the Main Camera Access capability.” and "Provisioning profile [Profile Name] doesn't include the com.apple.developer.arkit.main-camera-access.allow entitlement.” The provisioning profile we are attempting to use DOES have the Main Camera Access capability enabled through the Apple Developer portal. We have tried deleting and remaking the profile multiple times, as well as creating new profiles with the same settings, but completely different names and bundle identifiers, but keep getting the same errors. We DO have the "com.apple.developer.arkit.main-camera-access.allow” added to the entitlements file of the Xcode project, and we DO have the “NSMainCameraUsageDescription” key added to the info.plist file, along with the needed string describing the camera usage. Our organization has a valid and active Enterprise account, through which we have requested and been granted access to the “Main Camera Access” capability. We have built this applications multiple times before in the past year with no issues, these errors began after one of our provisioning profiles expired and we re-made it. We have tried clearing the Provisioning Profile Cache on our machine, clearing the Derived Data in the Xcode settings, and clearing the Xcode build cache. We are experiencing these errors on multiple machines, with different versions of our app, and with completely different apps that use the Main Camera Access entitlement. We experience these errors when the profile is downloaded directly in Xcode, and when it is downloaded from a browser and imported into Xcode. When we use “Automatically manage signing” our app properly builds and deploys to the Vision Pro, but when we use the app and attempt to access the main camera, the app crashes with the exception: "Exception: This app failed to request an authorization.” We have searched online forums and found several instances of others that have experienced this problem, but have not found a solution that works. Software Versions: Xcode Version: 26.6 macOS Version: Tahoe 26.5.1 VisionOS Version: 26.5
1
0
214
1w
Resolving a "Simulator runtime is not available" error
Some Macs recently received a macOS system update which disabled the simulator runtimes used by Xcode 15, including the simulators for iOS, tvOS, watchOS, and visionOS. If your Mac received this update, you will receive the following error message and will be unable to use the simulator: The com.apple.CoreSimulator.SimRuntime.iOS-17-2 simulator runtime is not available. Domain: com.apple.CoreSimulator.SimError Code: 401 Failure Reason: runtime profile not found using "System" match policy Recovery Suggestion: Download the com.apple.CoreSimulator.SimRuntime.iOS-17-2 simulator runtime from the Xcode To resume using the simulator, please reboot your Mac. After rebooting, check Xcode Preferences → Platforms to ensure that the simulator runtime you would like to use is still installed. If it is missing, use the Get button to download it again. The Xcode 15.3 Release Notes are also updated with this information.
Replies
0
Boosts
0
Views
11k
Activity
May ’24
Xcode 26.0 through 26.6 fails to open on M2 MacBook Air with Tahoe 26.6.1
Everything has been updated. Countless reboots and reinstalls. Yet Xcode still won't open. Keep getting "Xcode quit unexpectedly dialog" with buttons to Reopen, Ignore, Report. Any suggestions on what lingering file is killing Xcode on open? Thanks!
Replies
2
Boosts
1
Views
358
Activity
3h
Xcode 27 beta: "Missing package product" for a Swift Package in a registry
I have a project that builds fine in macOS 26 with Xcode 26. On macOS 27 b4 and Xcode beta, the same project can't build because of a framework that should be pulled from a Swift Package from a package-registry (named Registry, for example below), hosted on JFrog. I have the registry set up and have the token in keychain. The resolution of the packages works. But when I build, I get error like this: error: Missing package product 'Registry.Package_Package.Package' (in target 'Target' from project 'Project') . The real package should just be 'Registry.Package'. Any help with that? Is it a bug?
Replies
11
Boosts
2
Views
1.3k
Activity
10h
iOS 17 simulator is unresponsive in Device Hub
The iOS 17 simulator does not respond at all when I try to interact with it. The simulator is not frozen as I can still control appearance and launch apps via the right sidebar. Things like the home button and clicking on the screen simply don’t work. I am using Xcode 27 beta 6. Feedback ID: FB24674634
Replies
1
Boosts
1
Views
156
Activity
2d
Attributes inspector in Xcode 26
It has been two years since I wrote my a SwiftUI app, and I wanted to start again in Xcode 26. I can no longer see the attributes inspector when I select an element in the canvas. This was an Xcode feature that was very helpful as I am still a novice. Has this feature been deprecated in Xcode 26? And if not, please help explain how I can find and use it.
Replies
4
Boosts
6
Views
1.3k
Activity
2d
XCode 27b6 XCUITest clone simulators not visible in Device Hub (No Show Parallel Testing Devices)
Tried to execute our XCUITest test suite with XCode 27b6. The test plan is set to run in parallel. When executing tests locally with XCode 26, I can see the clone simulators executing the test (which is useful for debugging the test). With XCode 27b6 and Device Hub, I do not see the clone simulators executing, nor do I see a setting or menu item in Device Hub to show those clone simulators. There is no equivalent to the "Show Parallel Testing Devices" menu item in the XCode 26 sim. Am I missing something or is this a regression in XCode 27?
Replies
1
Boosts
3
Views
164
Activity
3d
Xcode's Background Assets Run scheme option
I just saw the following in the Xcode 27 release notes: Xcode can now serve asset packs to your app while debugging on devices by setting a Background Asset Packs folder in the Run scheme action’s Options tab. (165230494) And sure enough, the option is there. But what do I need to point this to? I tried everything: the path to the built .aar asset pack the path to the .json manifest file the path to the download-manifest.json (for self-hosted asset packs) the path to the directory that actually contains the assets (as also referenced by the manifest file) the path to the directory that contains the manifest file and the asset directory. Nothing works. I always get the same errors on the console: Checking for updates failed: DecodingError.dataCorrupted: Data was corrupted. Debug description: The given data was not valid JSON.. Underlying error: Error Domain=NSCocoaErrorDomain Code=3840 "Unexpected end of file" UserInfo={NSDebugDescription=Unexpected end of file} The asset pack with the ID “MyID” couldn’t be looked up: DecodingError.dataCorrupted: Data was corrupted. Debug description: The given data was not valid JSON.. Underlying error: Error Domain=NSCocoaErrorDomain Code=3840 "Unexpected end of file" UserInfo={NSDebugDescription=Unexpected end of file} The manifest couldn’t be refreshed: DecodingError.dataCorrupted: Data was corrupted. Debug description: The given data was not valid JSON.. Underlying error: Error Domain=NSCocoaErrorDomain Code=3840 "Unexpected end of file" UserInfo={NSDebugDescription=Unexpected end of file} I'm testing on a physical iPhone. Any advice would be appreciated!
Replies
0
Boosts
0
Views
70
Activity
3d
How to add custom macOS target properties in a SwiftUI Multi-platform target
How do you add custom macOS target properties in a SwiftUI Multi-platform target? I only see custom iOS target properties. I want to add keys such as BAAppGroupID, but only for macOS.
Replies
0
Boosts
0
Views
247
Activity
3d
can not create iOS 27 Simulator
Apple M1 Pro, 26.5.1 (25F80) XCode 27.0 Beta (27A5194q) Command Line tools for Xcode 27 are installed. Device Hub Version 27.0 (235.4.2) Within device hub I can not create iOS 27 simulators. Only the 26.5 simulators are listed there. I installed the iOS 27.0 SDK. Also deleted and reinstalled it. The computer was restarted. No change. I am unable to create the proper iOS 27 Simulators. Any idea why this is not working? Thanks for the help upfront.
Replies
14
Boosts
1
Views
1.6k
Activity
3d
Xcode 27: Bugs / Feedbacks
Hi, I have listed below the Feedbacks for Xcode 27, please have a look at it, considerable time was spent on filing these feedbacks, thanks! Environments All of them were tested on the environment: macOS 26.5.1 (25F80) Xcode 27.0 beta (27A5194q) Feedbacks FB23133706 (Git stage tab) FB23132869 (markdown - code block) FB23132403 (markdown - search) FB23078039 (stash - slow / unresponsive) FB23077930 (stash - allow multiselection) FB23055381 (Run destination - Clear recents) FB23041713 (SwiftUI preview - SwiftData) FB23033844 (Bundle ID) FB23033231 (Device Hub - sizes)
Replies
13
Boosts
1
Views
1.6k
Activity
3d
iOS 27 & watchOS 27 Simulator runtimes download but never register (signatureState never becomes "verified")
Environment Xcode 27.0 (Build 27A5194q) macOS 27.0 (Build 26A5353q), Apple Silicon Command Line Tools 27.0 Summary The iOS 27.0 (24A5355p) and watchOS 27.0 (24R5289n) Simulator runtimes download and mount successfully, but never register as usable. Both fail in exactly the same way. Every older runtime (e.g. iOS 26.2 / 23C54) works fine. What I see xcrun simctl list runtimes does NOT list iOS 27 or watchOS 27. They appear only under xcrun simctl runtime list (disk images), as: iOS 27.0 (24A5355p) State: Ready Image Kind: Patchable Cryptex Disk Image Signature State: Unknown Mount Path: /private/var/run/com.apple.security.cryptexd/mnt/... They never get promoted to /Library/Developer/CoreSimulator/Volumes/ the way working runtimes do. Where it actually breaks simdiskimaged finds and mounts the runtime with no error: "Found runtime bundle on disk image at: .../iOS 27.0.simruntime" "Got supported architectures back ... arm64" The runtime IS present in /Library/Developer/CoreSimulator/Images/images.plist, and its cryptex personalization manifest exists in /Library/Developer/CoreSimulator/Cryptex/Personalization/. BUT iOS 27 (24A5355p) and watchOS 27 (24R5289n) are the ONLY two images in the index whose signatureState is not verified. Every other runtime shows signatureState => verified. CoreSimulatorService therefore never registers them. So the cryptex mounts and the personalization ticket is present, but signature verification against that manifest never completes for these two new runtimes. Things I have already tried (no change) Deleted and re-downloaded the runtime via xcodebuild -downloadPlatform iOS (fresh image, identical result) Restarted CoreSimulatorService; ran sudo xcodebuild -runFirstLaunch Full reboot (cryptex re-mounts at boot but is still never verified/promoted) Deleted images.plist and let it rebuild Verified: system clock correct; gs.apple.com and ppq.apple.com reachable on 443; ~85 GB free disk; iphoneos27.0 SDK build (24A5355p) matches the downloaded runtime; simctl runtime match list shows 24A5355p as the chosen/default runtime. The standalone Simulator runtime .dmg for iOS 27 is not yet on Developer Downloads, so xcrun simctl runtime add isn't an option. Questions Is anyone else seeing iOS 27 / watchOS 27 runtimes stuck at Signature State: Unknown / signatureState != verified on this beta? Is there a way to force re-verification of an already-downloaded cryptex runtime without a standalone .dmg? Is this a known issue in the current beta? (FB filed.) Thanks!
Replies
2
Boosts
1
Views
422
Activity
4d
Internal PDF links stop working on iOS 27 / macOS 27 beta — every link opens the first page
On iOS 27 beta / Xcode 27.0, PDFDocument.write(to:) no longer serializes destinations for link annotations that are created at runtime. The annotation and its PDFActionGoTo action are both written, but the destination's page reference is not, so every internal link is dead. This worked correctly on iOS 26. PDFs generated on iOS 26 still navigate correctly; the same code on iOS 27 beta produces PDFs whose links are all dead.
Replies
1
Boosts
3
Views
391
Activity
4d
Build behaving differently in testflight compared to simulator
Hi all I have an app I’m pretty much done with, and on the Xcode simulator it works perfectly and the IAP shows us when the purchase buttons are clicked but for some reason when it goes to testflight none of the buttons respond, is there any reason that would cause it to behave differently in testflight when its coded correctly and works in the simulator. thanks
Replies
0
Boosts
0
Views
126
Activity
1w
Xcode MCP: Is Swift Package dependency management supported?
Hi Apple, I’m exploring the built-in MCP support in Xcode 27 and noticed that the available Xcode MCP tools don’t seem to provide a way for an agent to manage Swift Package dependencies. For example, an agent can inspect and modify source code, build the project, run tests, and diagnose build issues. However, I haven’t found an MCP tool that allows the agent to perform operations such as: Add a Swift Package dependency to an Xcode project Remove a Swift Package dependency Add/remove a package product from a target Change the version/branch/revision requirement of a package dependency For example, I’d like to be able to give an agent an instruction such as: Add https://github.com/xxx/SomePackage.git to the project, use version 1.2.0 or later, and link the SomePackage product to the MyApp target. At the moment, it appears that the agent can identify that the package is missing when compilation fails, but it cannot actually perform the package configuration step through the Xcode MCP tools. Is Swift Package dependency management intentionally not exposed through Xcode MCP at this time? If it is not currently supported, are there plans to expose APIs/tools for managing: Package dependencies Package products Target-package relationships Package version requirements This would be particularly useful for coding agents, since adding a dependency is a common part of an otherwise automated development workflow. I've submitted a request to feedback, the id is FB24676163. Thanks!
Replies
0
Boosts
0
Views
83
Activity
1w
AppStore Upcoming Requirement - Scene Delegate Migration Enforcement
My apps are legacy codebases still using AppDelegate instead of SceneDelegate. According to TN3187: Migrating to the UIKit scene-based life cycle, apps should migrate to the scene-based lifecycle. I have the following questions: Is there a specific timeline or deadline for when this migration will be enforced? Will there be deprecation warnings before the assert is triggered? I've tested my app with Xcode 27 beta, and it's not showing any errors or warnings related to this requirement. Based on this, I'm assuming this scene delegate migration may not be relevant for Apple's yearly requirement to submit new apps with the latest iOS SDK, and won't be enforced in April when "apps uploaded to App Store Connect must be built with Xcode 27 or later using an SDK for iOS 27." Can someone confirm if this understanding is correct?
Replies
2
Boosts
0
Views
304
Activity
1w
Is it a known issue that Xcode static analyzer hallucinates past results?
[Q] Is it a known issue that the Xcode static analyzer hallucinates past results? Basically, the issue I've been observing for a few releases of Xcode now (including 27b) is that if you run a static analysis, fixes the reported issues and re-run a static analysis, you will get exactly the same results as with the first run. It's as if Xcode did not take into account the fixes. If you clean the builds (cmd + shift + K), and run the analysis again, this time, you will get up-to-date results.
Replies
1
Boosts
0
Views
388
Activity
1w
Running tests in Xcode creates random folder Library/Containers/MyApp/Data with .profraw file
I was looking for my app's Application Support folder and was confused to see hundreds of folders with names like 36FE5C78-6D16-4556-8F13-80B0F2E7AD4B-84238-0000088F9B63C05B cluttering the Data folder. Some of these folders are empty, some contain a file named something like 791DC593-238F-4180-9D5D-6ABB7D22A4D3-18720.profraw. It seems that whenever I run any of my tests in Xcode, a new folder is generated and all the old ones are never removed. What's the purpose of these folders and why are they not removed automatically?
Replies
0
Boosts
0
Views
184
Activity
1w
How to simulate the Display Zoom setting on the XCode Simulator
Is there a way to simulate Display Zoom settings under the Appearance tab in Settings on a device simulator? I can only find this setting in my real device.
Replies
1
Boosts
0
Views
118
Activity
1w
Xcode 14 try to build all SPM when building swiftUI preview
HI, I have an issue displaying SwiftUI previews with Xcode 14. My project has iOS and an watchOS Target. It also includes a lot of SPM, most of them only used by the PhoneApp. The project build successfully for both iOS and watchOS. I can see that when building the watch target, only SPM that are included in this target are build for for watchOS The issue is when I try to build a swiftUI preview of the watch target. In this case I can see on the build for Preview log that Xcode try to build ALL spm defined in the Xcode project, including the one that are not used by the watch Target, As a lot if spm are for iOS only, and doesn't build for watchOS, the build for preview fails, and I'm unable to preview my swiftUI views on the AppeWatch. Note that my project is working fine on Xcode 13. This issue is easy to reproduce in any Xcode projects containing a iOS and watchOS target by adding a SPM that is only for iOS. Any workaround to fix this issue ?
Replies
18
Boosts
7
Views
7.4k
Activity
1w
Main Camera Access" Capability Missing from Provisioning Profile in Xcode, but is Enabled in Developer Portal
When attempting to build an Apple Vision Pro application written in Swift in Xcode, we get the following status errors: "Provisioning profile [Profile Name] doesn't include the Main Camera Access capability.” and "Provisioning profile [Profile Name] doesn't include the com.apple.developer.arkit.main-camera-access.allow entitlement.” The provisioning profile we are attempting to use DOES have the Main Camera Access capability enabled through the Apple Developer portal. We have tried deleting and remaking the profile multiple times, as well as creating new profiles with the same settings, but completely different names and bundle identifiers, but keep getting the same errors. We DO have the "com.apple.developer.arkit.main-camera-access.allow” added to the entitlements file of the Xcode project, and we DO have the “NSMainCameraUsageDescription” key added to the info.plist file, along with the needed string describing the camera usage. Our organization has a valid and active Enterprise account, through which we have requested and been granted access to the “Main Camera Access” capability. We have built this applications multiple times before in the past year with no issues, these errors began after one of our provisioning profiles expired and we re-made it. We have tried clearing the Provisioning Profile Cache on our machine, clearing the Derived Data in the Xcode settings, and clearing the Xcode build cache. We are experiencing these errors on multiple machines, with different versions of our app, and with completely different apps that use the Main Camera Access entitlement. We experience these errors when the profile is downloaded directly in Xcode, and when it is downloaded from a browser and imported into Xcode. When we use “Automatically manage signing” our app properly builds and deploys to the Vision Pro, but when we use the app and attempt to access the main camera, the app crashes with the exception: "Exception: This app failed to request an authorization.” We have searched online forums and found several instances of others that have experienced this problem, but have not found a solution that works. Software Versions: Xcode Version: 26.6 macOS Version: Tahoe 26.5.1 VisionOS Version: 26.5
Replies
1
Boosts
0
Views
214
Activity
1w
Slow launch of app on iOS Simulator 26.4
Each time I launch a Debug version of the app on iOS Simulator, I see the Launch Screen presented and then about a 30-second delay before the app is responsive and debug output appears in the console panel. Filed FB22345091
Replies
11
Boosts
7
Views
2.0k
Activity
1w